import axios from '~/axios'

//添加法规
export function addLawsApi(data) {
    return axios.post('/basic/lindi/laws/addLaws', data)
}

//删除法规
export function deleteLawsByLawsIdApi(lawsId) {
    return axios({
        method: 'DELETE',
        url: '/basic/lindi/laws/deleteLawsByLawsId',
        params: {
            LawsId: lawsId
        }
    })
}

//修改法规
export function updateLawsByLawsIdApi(data) {
    return axios.put('/basic/lindi/laws/updateLawsByLawsId', data)
}

//获取法规列表 - 分页
export function getPageLawsListApi(params) {
    return axios({
        method: 'GET',
        url: '/basic/lindi/laws/getPageLawsList',
        params: params
    })
}

//获取法规详细信息
export function getLawsByLawsIdApi(lawsId) {
    return axios.get(`/basic/lindi/laws/getLawsByLawsId/${lawsId}`)
}